<?php

namespace app\models;

class Post extends \core\Model
{
    // 核心数据表名
    public $table = 'posts';
    // 核心数据表主键
    public $primaryKey  = 'id';

    public function profile($user_id)
    {
        return $this->model->where('id = ?', (int) $user_id)->fetch();
    }
}
